package com.ssy.lingxi.settle.accounts.controller.mobile;

import com.ssy.lingxi.common.controller.BaseController;
import com.ssy.lingxi.common.response.Wrapper;
import com.ssy.lingxi.settle.accounts.model.vo.request.GetMemberAccountConfigVO;
import com.ssy.lingxi.settle.accounts.model.vo.response.MemberAccountConfigVO;
import com.ssy.lingxi.settle.accounts.service.CorporateAccountConfigService;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import javax.validation.Valid;

/**
 * @menu App - 会员账户相关接口
 * @author 伍将
 * @date 2021/02/23
 **/
@RestController
@RequestMapping("/settle/accounts/mobile")
public class MobileAccountController extends BaseController {

    @Resource
    CorporateAccountConfigService corporateAccountConfigService;

    /**
     * 获取会员对公账户配置
     * @author 伍将
     * @date 2021/2/23
     **/
    @RequestMapping(value = "/account/getAccountConfig", method = RequestMethod.GET)
    public Wrapper<MemberAccountConfigVO> getAccountConfig(@Valid GetMemberAccountConfigVO getMemberAccountConfigVO) {
        return corporateAccountConfigService.getMemberAccountByMobile(getMemberAccountConfigVO);
    }
}
